home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Puzzle / collapse.swf / scripts / frame_12 / PlaceObject2_99_4 / CLIPACTIONRECORD onClipEvent(enterFrame).as next >
Encoding:
Text File  |  2006-06-13  |  533 b   |  18 lines

  1. onClipEvent(enterFrame){
  2.    timeElapsed = maxTime - (getTimer() - timeStart);
  3.    timeRealSeconds = Math.floor(timeElapsed / 1000);
  4.    timeMinutes = Math.floor(timeRealSeconds / 60);
  5.    trace(timeMinutes);
  6.    timeSeconds = timeRealSeconds - timeMinutes * 60;
  7.    if(timeSeconds < 10)
  8.    {
  9.       timeseconds = String("0" + timeseconds);
  10.    }
  11.    _root.timer = timeMinutes + ":" + timeSeconds;
  12.    _root.timeScore = timeRealSeconds;
  13.    if(timeSeconds <= 0 && timeMinutes <= 0)
  14.    {
  15.       _root.gotoAndStop("over");
  16.    }
  17. }
  18.